<script setup>
import HomeMenu from "@/components/HomeMenu.vue";
import HomeContent from "@/components/HomeContent.vue";
import {ref} from "vue";

const homeContent = ref(null);

function searchList(val) {
  console.log('搜索',val);
  homeContent.value.title = val
  homeContent.value.getDataList()
}
</script>

<template>
  <div style="background-color: #f2f2f2">
    <div class="home-view">
      <HomeMenu @search-list="searchList" />
    </div>
    <div>
      <HomeContent ref="homeContent" />
    </div>
  </div>
</template>

<style>
.home-view{
  background-image: url("../assets/【哲风壁纸】护眼-舒适.png");
  background-size: cover;
  width: 100%;
  height: 50vh;
  display: flex;
  justify-content: center;
  padding: 15px;
  background-position: center;
  border-radius: 10px;
}
</style>
